const mockIndexData = require("./src/json/data.json");
const mockHomeData = require("./src/json/cards.json");

module.exports = {
  configureWebpack: {
    devServer: {
      port: 8080,
      open: true,
      before(app) {
        app.get("/api/index", (req, res) => {
          res.json(mockIndexData)
        })
        app.get("/api/home", (req, res) => {
          res.json(mockHomeData)
        })
      }
    }
  }
}
